import greenfoot.*;  // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)

/**
 * Write a description of class Pedazos here.
 * 
 * @author (your name) 
 * @version (a version number or a date)
 */
public class Madera extends SmoothMover
{
    private static final Vector G =new Vector(90,1.5);
    private static final int F =20;
    public Madera()
    {
      int direccion=Greenfoot.getRandomNumber(360);
       int velocidad=Greenfoot.getRandomNumber(F);
       increaseSpeed(new Vector(direccion,velocidad));
      
       GreenfootImage img=getImage();
       int width=Greenfoot.getRandomNumber(30)+1;
       int heigth=Greenfoot.getRandomNumber(30)+1;
       img.scale(width,heigth);
       
       setRotation(Greenfoot.getRandomNumber(360));
    }
    /**
     * Act - do whatever the Pedazos wants to do. This method is called whenever
     * the 'Act' or 'Run' button gets pressed in the environment.
     */
    public void act() 
    {
       increaseSpeed(G);
       move();
    }    
}
